#include <iostream>
#include <stack>

template<typename T>
void print(const T& vec)
{
    std::cout << "size:" << vec.size() << std::endl;
    for(auto ite = vec.begin(); ite != vec.end(); ite++)
    {
        std::cout << *ite << " ";
    }
    std::cout << std::endl;

}

int main()
{
    std::stack<int> s;
    for(int i = 0; i < 10; i++)
    {
        s.push(i);
    }

    while(s.empty() == false)
    {
        std::cout<< s.top() <<std::endl;
        s.pop();
    }

    return 0;
}